package com.virtualightning.mvvm.impl.task

import java.io.Closeable

/**
 *  Anchor : Create by CimZzz
 *  Time : 2021/10/11 18:28
 *  包装的 Closeable 对象
 */
class SimpleCloseable<T>(
	private val obj: T,
	private val closeCallback: (T) -> Unit
): Closeable {
	override fun close() {
		closeCallback(obj)
	}
}